import { TagsItem } from '@/api/tags';
import { Select } from 'antd';
import FormItem from 'antd/es/form/FormItem';
import React from 'react';

interface Props {
    data: TagsItem[]
}

export default function AddForm({ data }: Props) {
  return (
    <>
      <FormItem label="标签" name="tagsName" required>
        <Select
          mode="tags"
          style={{ width: '100%' }}
          placeholder="请输入标签"
          options={data.map((it) => ({ value: it.tagName, disabled: true }))}
        />
      </FormItem>
    </>
  );
}
